## API Report File for "@backstage/plugin-pagerduty"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).

```ts
/// <reference types="react" />

import { ApiRef } from '@backstage/core-plugin-api';
import { BackstagePlugin } from '@backstage/core-plugin-api';
import { CardExtensionProps } from '@backstage/plugin-home-react';
import { ConfigApi } from '@backstage/core-plugin-api';
import { DiscoveryApi } from '@backstage/core-plugin-api';
import { Entity } from '@backstage/catalog-model';
import { FetchApi } from '@backstage/core-plugin-api';
import { JSX as JSX_2 } from 'react';
import { default as React_2 } from 'react';
import { ReactNode } from 'react';

// @public @deprecated (undocumented)
export const EntityPagerDutyCard: (
  props: EntityPagerDutyCardProps,
) => JSX_2.Element;

// @public (undocumented)
export type EntityPagerDutyCardProps = {
  readOnly?: boolean;
  disableChangeEvents?: boolean;
};

// @public @deprecated (undocumented)
export const HomePagePagerDutyCard: (
  props: CardExtensionProps<HomePagePagerDutyCardProps>,
) => JSX_2.Element;

// @public (undocumented)
export type HomePagePagerDutyCardProps = PagerDutyEntity & {
  readOnly?: boolean;
};

// @public (undocumented)
const isPluginApplicableToEntity: (entity: Entity) => boolean;
export { isPluginApplicableToEntity as isPagerDutyAvailable };
export { isPluginApplicableToEntity };

// @public (undocumented)
export interface PagerDutyApi {
  getChangeEventsByServiceId(
    serviceId: string,
  ): Promise<PagerDutyChangeEventsResponse>;
  getIncidentsByServiceId(
    serviceId: string,
  ): Promise<PagerDutyIncidentsResponse>;
  getOnCallByPolicyId(policyId: string): Promise<PagerDutyOnCallsResponse>;
  getServiceByEntity(entity: Entity): Promise<PagerDutyServiceResponse>;
  getServiceByPagerDutyEntity(
    pagerDutyEntity: PagerDutyEntity,
  ): Promise<PagerDutyServiceResponse>;
  triggerAlarm(request: PagerDutyTriggerAlarmRequest): Promise<Response>;
}

// @public (undocumented)
export const pagerDutyApiRef: ApiRef<PagerDutyApi>;

// @public (undocumented)
export type PagerDutyAssignee = {
  id: string;
  summary: string;
  html_url: string;
};

// @public @deprecated (undocumented)
export const PagerDutyCard: (props: EntityPagerDutyCardProps) => JSX_2.Element;

// @public @deprecated (undocumented)
export type PagerDutyCardProps = EntityPagerDutyCardProps;

// @public (undocumented)
export type PagerDutyChangeEvent = {
  id: string;
  integration: [
    {
      service: PagerDutyService;
    },
  ];
  source: string;
  html_url: string;
  links: [
    {
      href: string;
      text: string;
    },
  ];
  summary: string;
  timestamp: string;
};

// @public (undocumented)
export type PagerDutyChangeEventsResponse = {
  change_events: PagerDutyChangeEvent[];
};

// @public (undocumented)
export class PagerDutyClient implements PagerDutyApi {
  constructor(config: PagerDutyClientApiConfig);
  // (undocumented)
  static fromConfig(
    configApi: ConfigApi,
    dependencies: PagerDutyClientApiDependencies,
  ): PagerDutyClient;
  // (undocumented)
  getChangeEventsByServiceId(
    serviceId: string,
  ): Promise<PagerDutyChangeEventsResponse>;
  // (undocumented)
  getIncidentsByServiceId(
    serviceId: string,
  ): Promise<PagerDutyIncidentsResponse>;
  // (undocumented)
  getOnCallByPolicyId(policyId: string): Promise<PagerDutyOnCallsResponse>;
  // (undocumented)
  getServiceByEntity(entity: Entity): Promise<PagerDutyServiceResponse>;
  // (undocumented)
  getServiceByPagerDutyEntity(
    pagerDutyEntity: PagerDutyEntity,
  ): Promise<PagerDutyServiceResponse>;
  // (undocumented)
  triggerAlarm(request: PagerDutyTriggerAlarmRequest): Promise<Response>;
}

// @public (undocumented)
export type PagerDutyClientApiConfig = PagerDutyClientApiDependencies & {
  eventsBaseUrl?: string;
};

// @public (undocumented)
export type PagerDutyClientApiDependencies = {
  discoveryApi: DiscoveryApi;
  fetchApi: FetchApi;
};

// @public @deprecated (undocumented)
export type PagerDutyEntity = {
  integrationKey?: string;
  serviceId?: string;
  name: string;
};

// @public (undocumented)
export type PagerDutyIncident = {
  id: string;
  title: string;
  status: string;
  html_url: string;
  assignments: [
    {
      assignee: PagerDutyAssignee;
    },
  ];
  serviceId: string;
  created_at: string;
};

// @public (undocumented)
export type PagerDutyIncidentsResponse = {
  incidents: PagerDutyIncident[];
};

// @public (undocumented)
export type PagerDutyOnCall = {
  user: PagerDutyUser;
  escalation_level: number;
};

// @public (undocumented)
export type PagerDutyOnCallsResponse = {
  oncalls: PagerDutyOnCall[];
};

// @public @deprecated (undocumented)
const pagerDutyPlugin: BackstagePlugin<{}, {}>;
export { pagerDutyPlugin };
export { pagerDutyPlugin as plugin };

// @public (undocumented)
export type PagerDutyService = {
  id: string;
  name: string;
  html_url: string;
  integrationKey: string;
  escalation_policy: {
    id: string;
    user: PagerDutyUser;
    html_url: string;
  };
};

// @public (undocumented)
export type PagerDutyServiceResponse = {
  service: PagerDutyService;
};

// @public (undocumented)
export type PagerDutyTriggerAlarmRequest = {
  integrationKey: string;
  source: string;
  description: string;
  userName: string;
};

// @public (undocumented)
export type PagerDutyUser = {
  id: string;
  summary: string;
  email: string;
  html_url: string;
  name: string;
};

// @public (undocumented)
export function TriggerButton(props: {
  children?: ReactNode;
}): React_2.JSX.Element;

// @public (undocumented)
export class UnauthorizedError extends Error {}
```
